package io.itit.ecp.admin.provide.action.req;

import io.itit.grass.common.provide.action.validation.IAdd;
import io.itit.grass.common.provide.action.validation.IEnable;
import io.itit.grass.common.provide.action.validation.IUpdate;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.ToString;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Null;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.List;

/**
 * <p>
 *
 * @Author：Roy
 * @Description：数据范围参数
 * @Date：Create by 2024-01-17 16:55:06
 */
@Data
@ToString
@ApiModel("数据范围参数")
public class DataRangeReq implements Serializable {

    private static final long serialVersionUID = 1L;

    @Null(groups = IAdd.class)
    @NotBlank(groups = IUpdate.class)
    @ApiModelProperty("主键")
    private String id;

    @NotBlank(groups = IAdd.class)
    @ApiModelProperty("范围编码")
    private String rangeCode;

    @NotBlank(groups = {IAdd.class, IUpdate.class})
    @ApiModelProperty("范围名称")
    private String rangeName;

    @NotBlank(groups = {IAdd.class, IUpdate.class})
    @ApiModelProperty("范围级别(all:全部,project:按项目,edifice:按楼栋,floor:按楼层,room:按空间,company:按公司) >> distCode：ecp-admin.dataRange.rangeLevel")
    private String rangeLevel;

    @ApiModelProperty("描述")
    private String remark;

    @NotBlank(groups = IEnable.class)
    @ApiModelProperty("状态(1:启用,2:禁用) >> distCode：ecp-admin.dataRange.status")
    private String status;

    @ApiModelProperty("关联场景Id集合")
    private List<String> sceneIdList;

    @ApiModelProperty("机构Id")
    private String deptId;

}